/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package javalens.util;

import javalens.util.Util;

/**
 *
 * @author vermaak
 */
public class Position {
    private double x;
    private double y;

    public Position(double x, double y) {
        this.x = x;
        this.y =  y;
    }

    public double getX() {
        return x;
    }

    public void setX(double x) {
        this.x = x;
    }

    public double getY() {
        return y;
    }

    public void setY(double y) {
        this.y = y;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final Position other = (Position) obj;
        if (!Util.equals(this.x, other.x,1.0e-15)) {
            return false;
        }
        if (!Util.equals(this.y, other.y,1.0e-15)) {
            return false;
        }
        return true;
    }
}
